package com.spring.test.feign.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import com.spring.test.feign.service.HelloService;

@RestController
public class ConsumerController {
    @Autowired
    private HelloService helloService;

    @GetMapping(value = "/hi")
    public String hiConsumer(@RequestParam String name) {
        return helloService.home(name);
    }
    
    @GetMapping(value = "/hello")
    public String hell() {
        return helloService.hello();
    }
}
